import styles from "../styles/info.module.css"; import { getInfoURL } from "../../../../utils/movie_urls"; import Image from "next/image"; import { PiThumbsUpFill } from "react-icons/pi"; import { FaRegCheckCircle } from "react-icons/fa"; import { RxDividerVertical } from "react-icons/rx"; import { FaDollarSign } from "react-icons/fa"; import { FaSackDollar } from "react-icons/fa6"; import VIDEO_PLAYER from "../components/video_player"; export default async function MOVIE_INFO({ params }) { const id = params.id; const data = await get_movie_info(id); return (
Movie Poster

{data.title || "Not found"}

{data.tagline || "Not found"}

{data.overview || "Not found"}

{data.vote_average || "Not found"}

{data.vote_count || "Not found"}

$ {data.revenue.toLocaleString() || "Not found"}

$ {data.budget.toLocaleString() || "Not found"}

Release Date: {data.release_date}

{data.genres.map((item) => (

{item.name || "Not found"}

))}

NOTE: Please wait for some time for the video to load. If it buffers for a long time, then try chanding the server. If the issue persists, please check your internet connection.



); } const get_movie_info = async (id) => { const res = await fetch(getInfoURL(id), { next: { revalidate: 21620 } }); const data = await res.json(); return data; };